package app.common.utils.wdt.sdk.taobao;

import com.taobao.api.BaseTaobaoRequest;

import java.text.SimpleDateFormat;

/**
 * @author feizns
 * @since 2023/4/20
 */
public class Config {

    private static final SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
    private static final String serverUrl = "http://3ldsmu02o9.api.taobao.com/top/router/qm";
    private static final String appKey = "34331853";// 自己的appkey
    private static final String appSecret = "f169f72d0be4fd0ef4412dbd494fafaa";// 自己的appsecret
    private static final String targetAppKey = "34331853";// WDT的appkey
    private static final String wdtAppKey = "34331853";
    private static final String wdtAppSecret = "af5ed5b3dbd456357748fb995510fff5:45629849787249829634d47028365251";
    private static final String wdtSalt = wdtAppSecret.split(":")[1];
    private static final String wdtSecret = wdtAppSecret.split(":")[0];

    /**
     * 应用
     * @param request 请求
     */
    public static void apply(BaseTaobaoRequest<?> request) {
        long timestamp = System.currentTimeMillis();
//        request.setTimestamp(timestamp);
//        request.setTargetAppKey();
//        request
//        String dateTime = sdf.format(new Date());
//        request.setDatetime(dateTime);
//        request.setWdtAppkey(wdtAppKey);
//        request.setWdtSalt(wdtSalt);
//        request.setWdtSign(Utils.getQimenCustomWdtSign(request, wdtSecret));
    }

}
